<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<%@page import="java.io.PrintWriter" %>
<%@page import="java.util.ArrayList" %>
<style type="text/css">
body{ text-align: justify;background-color:orange; font-family: Cambria}
h1{text-align: center; color: black;font-family: Cambria;}
form{font-family: Cambria;}</style>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Drop</title>
</head>

<body>
<%
PrintWriter pw = response.getWriter();
pw.println("<html>");
pw.println("<style type='text/css'>	body{ text-align: justify;background-color:orange; font-family: Cambria} h1{text-align: center; color: black;font-family: Cambria;}	form{font-family: Cambria;}</style>");
pw.println("<h1>Drop Courses</h1>");
pw.print("<label>Student Name : </label>");
String name = (String)request.getAttribute("name");
String suid = (String)request.getAttribute("suid");
pw.print("<label>"+name+"</label><br>");
request.getSession().setAttribute("sname", name);
request.getSession().setAttribute("suid", suid);
pw.print("<label>Student ID : </label>");
pw.print("<label>"+suid+"</label><br>");
pw.println("<form action='dropCourses' method='post'>");
pw.println("<fieldset>");
ArrayList<String> x = (ArrayList<String>) request.getAttribute("courses");
pw.println("<legend>Drop</legend>");
for(String s : x)
{
	pw.println("<input type='checkbox' name='course' value='"+s+"'>"+s+"<br>");
}
pw.println("</fieldset>");
pw.println("<input type='submit' value='Drop'>");
pw.println("<INPUT Type='button' VALUE='Back' onClick='history.go(-1);return true;'>");

pw.println("</form>");
pw.println("</html>");
%>
</body>
</html>